package com.tt.job;

import com.tt.job.util.SpringUtils;
import org.springframework.boot.SpringApplication;
import org.springframework.boot.autoconfigure.SpringBootApplication;
import org.springframework.boot.autoconfigure.jdbc.DataSourceAutoConfiguration;
import org.springframework.context.ApplicationContext;

/**
 * 任务调度器入口函数
 */
@SpringBootApplication(exclude = {DataSourceAutoConfiguration.class})
public class JobScheduler {
    /**
     * TODO中的都是第一个版本不实现的
     *
     * @param args
     */
    public static void main(String[] args) {
        SpringApplication application = new SpringApplication(JobScheduler.class);
        //application.setWebEnvironment(false);
        ApplicationContext context = application.run(args);
        SpringUtils.setContext(context);
        System.out.println("started job server SUCCESS.");
    }
}
